
import axios from 'axios';

/**
 * 维修单状态记录
 */
export class RepairOrderStatusRecordService {
    // 分页查询列表
    static findRepairOrderStatusRecords (queryParams) {
        return axios({
            url: '/repair/repairManagement/RepairOrderStatusRecord/findRepairOrderStatusRecords',
            method: 'POST',
            data: queryParams
        });
    }

    //根据ID查询指定的维修单状态记录
    static findRepairOrderStatusRecord (repairOrderStatusRecordId) {
        const query = {
            repairOrderStatusRecordId
        }
        return axios({
            url: '/repair/repairManagement/RepairOrderStatusRecord/findRepairOrderStatusRecord',
            method: 'POST',
            params: query,
        });
    }

    //根据ID查询指定的维修单状态记录(包含外键名称)
    static findRepairOrderStatusRecordForView (repairOrderStatusRecordId) {
        const query = {
            repairOrderStatusRecordId
        }
        return axios({
            url: '/repair/repairManagement/RepairOrderStatusRecord/findRepairOrderStatusRecordForView',
            method: 'POST',
            params: query,
        });
    }

    //根据ID查询指定的维修单状态记录(包含外键名称)
    static findRepairOrderStatusRecordForEdit (repairOrderStatusRecordId) {
        const query = {
            repairOrderStatusRecordId
        }
        return axios({
            url: '/repair/repairManagement/RepairOrderStatusRecord/findRepairOrderStatusRecordForEdit',
            method: 'POST',
            params: query,
        });
    }

    //根据ID查询指定的维修单状态记录(只提取ID 和 Name)
    static findRepairOrderStatusRecordsWithIdNameById (repairOrderStatusRecordId) {
        const query = {
            repairOrderStatusRecordId
        }
        return axios({
            url: '/repair/repairManagement/RepairOrderStatusRecord/findRepairOrderStatusRecordsWithIdNameById',
            method: 'POST',
            params: query,
        });
    }

    //根据名称查询维修单状态记录集合(只提取ID 和 Name)
    static findRepairOrderStatusRecordsWithIdNameByName (repairOrderStatusRecordName) {
        const query = {
            repairOrderStatusRecordName
        }
        return axios({
            url: '/repair/repairManagement/RepairOrderStatusRecord/findRepairOrderStatusRecordsWithIdNameByName',
            method: 'POST',
            params: query,
        });
    }

    //新增保存维修单状态记录
    static saveRepairOrderStatusRecord (repairOrderStatusRecord) {
        const query = {}
        return axios({
            url: '/repair/repairManagement/RepairOrderStatusRecord/saveRepairOrderStatusRecord',
            method: 'POST',
            params: query,
            data: repairOrderStatusRecord
        });
    }

    //修改保存维修单状态记录
    static updateRepairOrderStatusRecord (repairOrderStatusRecord) {
        const query = {}
        return axios({
            url: '/repair/repairManagement/RepairOrderStatusRecord/updateRepairOrderStatusRecord',
            method: 'POST',
            params: query,
            data: repairOrderStatusRecord
        });
    }

    //根据ID查询指定的维修单状态记录(只提取ID 和 Name)
    static deleteRepairOrderStatusRecord (repairOrderStatusRecordId) {
        const query = {
            repairOrderStatusRecordId
        }
        return axios({
            url: '/repair/repairManagement/RepairOrderStatusRecord/deleteRepairOrderStatusRecord',
            method: 'POST',
            params: query,
        });
    }
}
